#!/sbin/openrc-run
# Copyright 1999-2018 Gentoo Authors
# Distributed under the terms of the GNU General Public License v2

command="/usr/sbin/amavis-mc"
pidfile="/run/${RC_SVCNAME}.pid"

# Let OpenRC background this, because otherwise it will write its PID
# file after dropping privileges which presents a security issue when
# we go to `kill` the thing as root.
command_args="-f"
command_background="true"
command_user="amavis:amavis"

depend() {
  use logger
  before amavisd-new snmpd
}
